
import java.io.File;
import java.io.IOException;
import java.lang.String;
import java.util.ArrayList;
import java.util.Date;
import java.util.Map;
import java.util.HashMap;
import java.util.List;
import java.util.Vector;

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author danilo
 */
public class Teste {

    public static void main( String[] args ) throws IOException{
        Map<String, Long> mapa = new HashMap<String, Long>();
        getLocalTree( new File("."), mapa, 0 );

        for( String s: mapa.keySet() ){
            //System.out.println( s + "->" + mapa.get(s) );
        }

        for( List<String> l: vec ){
            for( String s: l){
                System.out.println( s );
            }
        }
    }


    static Vector<List<String>> vec = new Vector<List<String>>();

    public static void getLocalTree( File arg, Map<String, Long> map, int nivel ) throws IOException{

        if( vec.size() <= nivel ){
            vec.add( new ArrayList<String>() );
        }

        vec.get(nivel).add( arg.getPath() );

        for( File f: arg.listFiles() ){
            if( f.isDirectory() )
                getLocalTree(f, map, nivel + 1);
            else{
                for( int i = 0; i < nivel; i++ ) System.out.print("\t");
                //System.out.println( arg.getPath() + "/" + f.getName() );
                Date d = new Date( f.lastModified() );
                System.out.println( "*****" + f.getName() + " - " + d );
                map.put( arg.getPath() + "/" + f.getName(), f.lastModified() );
            }
        }

    }


}
